<!DOCTYPE html>
<html lang="en-US">
    <head>
        <title>Email::Stuffer - A more casual approach to creating and sending Email:: emails - metacpan.org</title>
        <link rel="preload" as="fetch" href="https://metacpan.org/account/login_status" crossorigin="anonymous" />
        <link href="https://metacpan.org/_assets/b8ccceeed47a0652049703d99326a9cea4933443.css" rel="stylesheet" type="text/css">
        <script src="https://metacpan.org/_assets/6bfedafe2d7caa915b7d84f61b45936818e3242e.js" type="text/javascript" defer></script>
        <link rel="alternate" type="application/rss+xml" title="Recent CPAN Uploads of Email-Stuffer - MetaCPAN" href="https://metacpan.org/dist/Email-Stuffer/releases.rss" />
        <link rel="canonical" href="./Email::Stuffer.html" />
        <meta name="description" content="A more casual approach to creating and sending Email:: emails" />
        <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=5">
        <link rel="shortcut icon" href="https://metacpan.org/static/icons/favicon.ico">
        <link rel="apple-touch-icon" sizes="152x152" href="https://metacpan.org/static/icons/apple-touch-icon.png">
        <link rel="search" href="https://metacpan.org/static/opensearch.xml" type="application/opensearchdescription+xml" title="MetaCPAN">
        <script>
          (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){
          (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o),
          m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m)
          })(window,document,'script','//www.google-analytics.com/analytics.js','ga');

          (function(skey, ga_id){
            ga('create', ga_id, {
              siteSpeedSampleRate : 100,
              storage             : 'none',
              clientId            : localStorage.getItem(skey)
            });
            ga(function(tracker) {
              localStorage.setItem(skey, tracker.get('clientId'));
            });
            ga('send', 'pageview');
          })('ga:clientId', 'UA-27829474-1');
        </script>
<meta name="twitter:card"        content="summary" />
<meta name="twitter:url"         content="https://metacpan.org/pod/Email::Stuffer" />
<meta name="twitter:title"       content="Email::Stuffer" />
<meta name="twitter:description" content="A more casual approach to creating and sending Email:: emails" />
<meta name="twitter:site"        content="metacpan" />
    </head>
    <body>
        <nav class="navbar navbar-default" role="navigation">
            <div class="header-logo-large hidden-xs">
              <a href="https://metacpan.org/" tabindex="0">
                <svg class="logo" aria-label="MetaCPAN">
                  <use class="logo" href="/static/images/metacpan-logo.svg#logo" />
                </svg>
              </a>
            </div>
            <div class="header-logo-icon visible-xs">
              <a href="https://metacpan.org/">
                <svg class="logo" aria-label="MetaCPAN">
                  <use class="logo" href="/static/images/metacpan-logo.svg#dots" />
                </svg>
              </a>
            </div>
            <ul class="nav navbar-nav menu-items hidden-xs hidden-sm">
              <li><a href="https://metacpan.org/about">About</a></li>
              <li><a href="https://metacpan.org/about/sponsors">Sponsor</a></li>
              <li><a href="https://grep.metacpan.org/">grep::cpan</a></li>
              <li><a href="https://metacpan.org/recent">Recent</a></li>
              <li><a href="https://metacpan.org/about/faq">FAQ</a></li>
              <li><a href="https://metacpan.org/tools">Tools</a></li>
              <li><a href="https://fastapi.metacpan.org/">API</a></li>
            </ul>
            <ul class="nav navbar-nav navbar-right">
                <button type="button" class="searchbar-btn visible-xs visible-sm">
                    <i class="fa fa-search button-fa-icon"></i>
                </button>
                <form action="https://metacpan.org/search" class="searchbar-form visible-md visible-lg search-form form-horizontal">
                   <input type="hidden" name="size" id="metacpan_search-size" value="20">
                  <div class="form-group">
                      <div class="search-group">
                        <i class="fa fa-search"></i>
                        <input type="text" name="q" placeholder="Search the CPAN" size="41" autocorrect="off" autocapitalize="off" spellcheck="false" id="metacpan_search-input" class="form-control" value="">
                      </div>
                  </div>
                </form>
                    <li class="icon-slidepanel visible-xs visible-sm">
                      <button data-toggle="slidepanel" data-target=".slidepanel">
                        <span class="button-fa-icon">
                          <i class="fa fa-bars slidepanel-open"></i>
                          <i class="fa fa-times slidepanel-close"></i>
                        </span>
                      </button>
                    </li>
                <form action="https://metacpan.org/account/logout" method="POST" id="metacpan-logout"></form>
                <li class="dropdown logged_in" style="display: none;">
                    <button type="button" class="dropdown-toggle" data-toggle="dropdown">
                      <i class="fa fa-user button-fa-icon logged-in-icon" aria-hidden="true"></i>
                      <i class="fas fa-chevron-down"></i>
                    </button>
                    <ul class="dropdown-menu">
                        <li><a href="https://metacpan.org/account/identities">Identities</a></li>
                        <li><a href="https://metacpan.org/account/profile">Profile</a></li>
                        <li><a href="https://metacpan.org/account/favorite/list">Favorites</a></li>
                        <li>
                            <a href="./Email::Stuffer.html#" type="button" onclick="$('#metacpan-logout').submit(); return false">
                              Logout
                            </a>
                        </li>
                    </ul>
                </li>
                <li class="dropdown logged_out" style="display: none;">
                    <button type="button" class="dropdown-toggle" data-toggle="dropdown">
                      <i class="fa fa-user button-fa-icon" aria-hidden="true"></i>
                      <i class="fas fa-chevron-down"></i>
                    </button>
                    <ul class="dropdown-menu">
                        <li>
                            <a href="https://metacpan.org/login/github">
                                <i class="fab fa-github fa-fw"></i>
                                GitHub
                            </a>
                        </li>
                        <li>
                            <a href="https://metacpan.org/login/twitter">
                                <i class="fab fa-twitter fa-fw"></i>
                                Twitter
                            </a>
                        </li>
                        <li>
                            <a href="https://metacpan.org/login/google">
                                <i class="fab fa-google fa-fw"></i>
                                Google
                            </a>
                        </li>
                    </ul>
                </li>
                <li class="dropdown logged_placeholder">
                    <button>
                      <i class="fa fa-user button-fa-icon" aria-hidden="true"></i>
                    </button>
                </li>
            </ul>
        </nav>
        <div class="page-content ">
          <!--
          <div class="top-notify-banner">
            <i class="fas fa-info-circle"></i>
          </div>
          -->
          <nav class="sidebar">
            <div class="slidepanel">
              <ul class="nav-list ">
    <li class="nav-header no-margin-top">
      <div class="ttip" data-toggle="tooltip" data-placement="bottom" title="The date that this version of Email-Stuffer was released.">
      <span class="relatize">11 Jan 2023 01:50:03 UTC</span>
    </li>
  <li>
    Distribution: <a href="https://metacpan.org/dist/Email-Stuffer">Email-Stuffer</a>
  </li>
  <li>
    Module version: 0.020
  </li>
  <li>
    <a data-keyboard-shortcut="g s" href="https://metacpan.org/dist/Email-Stuffer/source/lib/Email/Stuffer.pm">Source</a>
    (<a href="https://metacpan.org/dist/Email-Stuffer/source/lib/Email/Stuffer.pm?raw=1">raw</a>)
  </li>
  <li>
    <a data-keyboard-shortcut="g b" href="https://metacpan.org/dist/Email-Stuffer/source/lib/Email">Browse</a>
    (<a href="https://metacpan.org/dist/Email-Stuffer/source/lib/Email?raw=1">raw</a>)
  </li>
    <li>
      <a data-keyboard-shortcut="g c" href="https://metacpan.org/dist/Email-Stuffer/changes">Changes</a>
    </li>
    <li>
      <a rel="noopener nofollow" class="nopopup" href="https://github.com/rjbs/Email-Stuffer">Homepage</a>
    </li>
    <li>
      <a class="nopopup" href="https://metacpan.org/dist/Email-Stuffer/contribute">How to Contribute</a>
    </li>
    <li>
        <a rel="noopener nofollow" data-keyboard-shortcut="g r" href="https://github.com/rjbs/Email-Stuffer">Repository</a>
    </li>
    <li>
      <a rel="noopener nofollow" data-keyboard-shortcut="g i" href="https://github.com/rjbs/Email-Stuffer/issues">Issues</a>
    </li>
    <li>
      <a rel="noopener nofollow" href="http://matrix.cpantesters.org/?dist=Email-Stuffer+0.020" title="Matrix">Testers</a>
        <span title="(pass / fail / na)">(<a rel="noopener nofollow" href="https://www.cpantesters.org/distro/E/Email-Stuffer.html?oncpan=1&amp;distmat=1&amp;version=0.020&amp;grade=2" style="color: #090">412</a> / <a rel="noopener nofollow" href="https://www.cpantesters.org/distro/E/Email-Stuffer.html?oncpan=1&amp;distmat=1&amp;version=0.020&amp;grade=3" style="color: #900">0</a> / <a rel="noopener nofollow" href="https://www.cpantesters.org/distro/E/Email-Stuffer.html?oncpan=1&amp;distmat=1&amp;version=0.020&amp;grade=4">9</a>)</span>
    </li>
    <li>
      <a rel="noopener nofollow" href="http://cpants.cpanauthors.org/release/RJBS/Email-Stuffer-0.020">Kwalitee</a>
    </li>
    <li>
      <div class="ttip" data-toggle="tooltip" data-placement="bottom" title="The # people with an indexing permission on Email-Stuffer who have released something to CPAN in the last 2 years (i.e. the # people likely able to release critical fixes in a timely manner)">
      Bus factor: 1
      </div>
    </li>
    <li>
      <a rel="noopener nofollow" href="http://cpancover.com/latest/Email-Stuffer-0.020/index.html">84.62% Coverage </a>
    </li>
    <li>
      License: perl_5
    </li>
    <li>
      Perl: v5.12.0
    </li>
    <li class="nav-header">Activity</li>
    <li>
<div class="activity-graph">
    <img src="https://metacpan.org/dist/Email-Stuffer/activity.svg?res=month" />
    <div class="comment">24 month</div>
</div>
    </li>
    <li class="nav-header">Tools</li>
    <li>
      <a itemprop="downloadUrl" href="https://cpan.metacpan.org/authors/id/R/RJ/RJBS/Email-Stuffer-0.020.tar.gz">
      Download (<span itemprop="fileSize">45.26KB</span>)</a>
    </li>
    <li>
      <a href="https://explorer.metacpan.org/?url=%2Fmodule%2FRJBS%2FEmail-Stuffer-0.020%2Flib%2FEmail%2FStuffer.pm">
        MetaCPAN Explorer
      </a>
    </li>
    <li>
      <a href="https://metacpan.org/dist/Email-Stuffer/permissions">
        Permissions
      </a>
    </li>
    <li>
      <a href="https://metacpan.org/dist/Email-Stuffer/releases.rss">
        Subscribe to distribution
      </a>
    </li>
    <li>
      <button class="btn btn-link" data-toggle="modal" data-target="#metacpan_install-instructions-dialog">
        Install Instructions
      </button>
    </li>
    <li>
      <form action="https://metacpan.org/search">
        <input type="hidden" name="q" value="dist:Email-Stuffer">
        <input type="search" name="q" placeholder="Search distribution" class="form-control tool-bar-form">
        <input type="submit" style="display: none">
      </form>
    </li>
    <li>
      <form action="https://grep.metacpan.org/search">
        <input type="hidden" name="qd" value="Email-Stuffer">
        <input type="hidden" name="source" value="metacpan">
        <input type="search" name="q" placeholder="grep distribution" class="form-control tool-bar-form">
        <input type="submit" style="display: none">
     </form>
    </li>
    <li class="version-jump">
<select onchange="document.location.href=&#39;/release/&#39;+this.value+&#39;/view/lib/Email/Stuffer.pm&#39;" class="form-control tool-bar-form">
  <option disabled selected>Jump to version</option>
<option
  disabled
  value="RJBS/Email-Stuffer-0.020"
>0.020
  (RJBS on 2023-01-11)</option>
<option
  
  value="RJBS/Email-Stuffer-0.019"
>0.019
  (RJBS on 2023-01-10)</option>
<optgroup label="BackPAN">'
<option
  
  value="RJBS/Email-Stuffer-0.018"
>0.018
  (RJBS on 2020-07-03)</option>
<option
  
  value="RJBS/Email-Stuffer-0.017"
>0.017
  (RJBS on 2018-03-10)</option>
<option
  
  value="RJBS/Email-Stuffer-0.016"
>0.016
  (RJBS on 2017-08-31)</option>
<option
  
  value="RJBS/Email-Stuffer-0.015-TRIAL"
>0.015-TRIAL DEV
  (RJBS on 2017-06-25)</option>
<option
  
  value="RJBS/Email-Stuffer-0.014"
>0.014
  (RJBS on 2016-04-30)</option>
<option
  
  value="RJBS/Email-Stuffer-0.013"
>0.013
  (RJBS on 2016-04-09)</option>
<option
  
  value="RJBS/Email-Stuffer-0.012"
>0.012
  (RJBS on 2015-02-16)</option>
<option
  
  value="RJBS/Email-Stuffer-0.011"
>0.011
  (RJBS on 2015-02-15)</option>
<option
  
  value="RJBS/Email-Stuffer-0.010-TRIAL"
>0.010-TRIAL DEV
  (RJBS on 2014-04-25)</option>
<option
  
  value="RJBS/Email-Stuffer-0.009"
>0.009
  (RJBS on 2013-11-25)</option>
<option
  
  value="RJBS/Email-Stuffer-0.008"
>0.008
  (RJBS on 2013-09-29)</option>
<option
  
  value="RJBS/Email-Stuffer-0.007"
>0.007
  (RJBS on 2013-08-22)</option>
<option
  
  value="RJBS/Email-Stuffer-0.006"
>0.006
  (RJBS on 2013-07-02)</option>
<option
  
  value="RJBS/Email-Stuffer-0.005"
>0.005
  (RJBS on 2013-07-02)</option>
<option
  
  value="RJBS/Email-Stuffer-0.004"
>0.004
  (RJBS on 2013-06-25)</option>
<option
  
  value="RJBS/Email-Stuffer-0.003"
>0.003
  (RJBS on 2013-06-19)</option>
<option
  
  value="RJBS/Email-Stuffer-0.002"
>0.002
  (RJBS on 2013-06-14)</option>
<option
  
  value="RJBS/Email-Stuffer-0.001"
>0.001
  (RJBS on 2013-05-30)</option>
</optgroup>
</select>
    </li>
    <li class="version-diff">
<select onchange="document.location.href='/release/RJBS/Email-Stuffer-0.020/diff/' + encodeURIComponent(this.value) + '/lib/Email/Stuffer.pm'
" class="form-control tool-bar-form">
  <option disabled selected>Diff with version</option>
<option
  disabled
  value="RJBS/Email-Stuffer-0.020"
>0.020
  (RJBS on 2023-01-11)</option>
<option
  
  value="RJBS/Email-Stuffer-0.019"
>0.019
  (RJBS on 2023-01-10)</option>
<optgroup label="BackPAN">'
<option
  
  value="RJBS/Email-Stuffer-0.018"
>0.018
  (RJBS on 2020-07-03)</option>
<option
  
  value="RJBS/Email-Stuffer-0.017"
>0.017
  (RJBS on 2018-03-10)</option>
<option
  
  value="RJBS/Email-Stuffer-0.016"
>0.016
  (RJBS on 2017-08-31)</option>
<option
  
  value="RJBS/Email-Stuffer-0.015-TRIAL"
>0.015-TRIAL DEV
  (RJBS on 2017-06-25)</option>
<option
  
  value="RJBS/Email-Stuffer-0.014"
>0.014
  (RJBS on 2016-04-30)</option>
<option
  
  value="RJBS/Email-Stuffer-0.013"
>0.013
  (RJBS on 2016-04-09)</option>
<option
  
  value="RJBS/Email-Stuffer-0.012"
>0.012
  (RJBS on 2015-02-16)</option>
<option
  
  value="RJBS/Email-Stuffer-0.011"
>0.011
  (RJBS on 2015-02-15)</option>
<option
  
  value="RJBS/Email-Stuffer-0.010-TRIAL"
>0.010-TRIAL DEV
  (RJBS on 2014-04-25)</option>
<option
  
  value="RJBS/Email-Stuffer-0.009"
>0.009
  (RJBS on 2013-11-25)</option>
<option
  
  value="RJBS/Email-Stuffer-0.008"
>0.008
  (RJBS on 2013-09-29)</option>
<option
  
  value="RJBS/Email-Stuffer-0.007"
>0.007
  (RJBS on 2013-08-22)</option>
<option
  
  value="RJBS/Email-Stuffer-0.006"
>0.006
  (RJBS on 2013-07-02)</option>
<option
  
  value="RJBS/Email-Stuffer-0.005"
>0.005
  (RJBS on 2013-07-02)</option>
<option
  
  value="RJBS/Email-Stuffer-0.004"
>0.004
  (RJBS on 2013-06-25)</option>
<option
  
  value="RJBS/Email-Stuffer-0.003"
>0.003
  (RJBS on 2013-06-19)</option>
<option
  
  value="RJBS/Email-Stuffer-0.002"
>0.002
  (RJBS on 2013-06-14)</option>
<option
  
  value="RJBS/Email-Stuffer-0.001"
>0.001
  (RJBS on 2013-05-30)</option>
</optgroup>
</select>
    </li>

    <li>
<ul class="dependencies">
  <li class="nav-header">Dependencies</li>
  <li><a href="https://metacpan.org/pod/Carp" title="Carp" class="ellipsis">Carp</a></li>
  <li><a href="./Email::MIME.html" title="Email::MIME" class="ellipsis">Email::MIME</a></li>
  <li><a href="https://metacpan.org/pod/Email::MIME::Creator" title="Email::MIME::Creator" class="ellipsis">Email::MIME::Creator</a></li>
  <li><a href="./Email::Sender::Simple.html" title="Email::Sender::Simple" class="ellipsis">Email::Sender::Simple</a></li>
  <li><a href="https://metacpan.org/pod/File::Basename" title="File::Basename" class="ellipsis">File::Basename</a></li>
  <li><a href="./Module::Runtime.html" title="Module::Runtime" class="ellipsis">Module::Runtime</a></li>
  <li><a href="https://metacpan.org/pod/Params::Util" title="Params::Util" class="ellipsis">Params::Util</a></li>
  <li><a href="https://metacpan.org/pod/Scalar::Util" title="Scalar::Util" class="ellipsis">Scalar::Util</a></li>
  <li><a href="https://metacpan.org/pod/warnings" title="warnings" class="ellipsis">warnings</a></li>
  <li>
    <hr>
  </li>
  <li>
    <a href="https://metacpan.org/module/Email::Stuffer/requires">Reverse dependencies</a>
  </li>
  <li>
    <a href="http://deps.cpantesters.org/?module=Email%3A%3AStuffer">CPAN Testers List</a>
  </li>
  <li>
    <a href="https://cpandeps.grinnz.com/?dist=Email-Stuffer">Dependency graph</a>
  </li>
</ul>
    </li>
    <li class="nav-header">Permalinks</li>
    <li>
      <a href="https://metacpan.org/release/RJBS/Email-Stuffer-0.020/view/lib/Email/Stuffer.pm">This version</a>
    </li>
    <li>
      <a href="./Email::Stuffer.html">Latest version</a>
    </li>
    <li>
<div class="plussers">
<div class="nav-header">++ed by:</div>
<div>
<a class="display-all" href="https://metacpan.org/author/TOKUHIROM"><img src="https://www.gravatar.com/avatar/70f90c6a0bcd84348b02309babc98684?d=identicon&amp;s=20" title="TOKUHIROM" alt="TOKUHIROM"></a>
<a class="display-all" href="https://metacpan.org/author/MHOWARD"><img src="https://www.gravatar.com/avatar/23ac2fbc91ec185f5da16627eb556667?d=identicon&amp;s=20" title="MHOWARD" alt="MHOWARD"></a>
<a class="display-all" href="https://metacpan.org/author/KARJALA"><img src="https://www.gravatar.com/avatar/9685932c4be47d9e6370f49230700c40?d=identicon&amp;s=20" title="KARJALA" alt="KARJALA"></a>
<a class="display-all" href="https://metacpan.org/author/ARISTOTLE"><img src="https://www.gravatar.com/avatar/81da52fa1b6754867e9056c58afab74d?d=identicon&amp;s=20" title="ARISTOTLE" alt="ARISTOTLE"></a>
<a class="display-all" href="https://metacpan.org/author/SRCHULO"><img src="https://www.gravatar.com/avatar/6e788aafb8d791ad29046296ee0c5e4b?d=identicon&amp;s=20" title="SRCHULO" alt="SRCHULO"></a>
</div>
<!-- Display counts of plussers-->
<div>
    <a href="https://metacpan.org/dist/Email-Stuffer/plussers">17 PAUSE users</a>
</div>
<div>
    17 non-PAUSE users
</div>
</div>
    </li>
    <li>
<div id="metacpan_contributors">
  <div>
    <button class="btn-link"
      onclick="$(this).hide(); $('#metacpan_contributors ul').slideDown(); return false;"
    >and 24 contributors</button>
  </div>
  <ul style="display: none">
    <li class="contributor"
      data-cpan-author="ADAMK"
      data-contrib-email="adamk@cpan.org adamk@cpan.org@88f4d9cd-8a04-0410-9d60-8f63309c3137"
    >
      <a href="https://metacpan.org/author/ADAMK" class="cpan-author">
      <img class="gravatar" width="20" height="20" src="https://www.gravatar.com/avatar/884124d0169f41668fb3f948b2ba8b0a?d=identicon&amp;s=20" />
      Adam Kennedy
      </a>
    </li>
    <li class="contributor"
      data-contrib-email="aaron.w.swenson@gmail.com"
    >
      <img class="gravatar" width="20" height="20" src="https://www.gravatar.com/avatar/d41d8cd98f00b204e9800998ecf8427e?d=identicon&amp;s=20" />
      Aaron W. Swenson
    </li>
    <li class="contributor"
      data-contrib-email="adam@88f4d9cd-8a04-0410-9d60-8f63309c3137"
    >
      <img class="gravatar" width="20" height="20" src="https://www.gravatar.com/avatar/d41d8cd98f00b204e9800998ecf8427e?d=identicon&amp;s=20" />
      adam
    </li>
    <li class="contributor"
      data-contrib-email="adam@phase-n.com@88f4d9cd-8a04-0410-9d60-8f63309c3137"
    >
      <img class="gravatar" width="20" height="20" src="https://www.gravatar.com/avatar/d41d8cd98f00b204e9800998ecf8427e?d=identicon&amp;s=20" />
      adam@phase-n.com
    </li>
    <li class="contributor"
      data-cpan-author="ALTREUS"
      data-contrib-email="altreus@altre.us"
    >
      <a href="https://metacpan.org/author/ALTREUS" class="cpan-author">
      <img class="gravatar" width="20" height="20" src="https://www.gravatar.com/avatar/f6ff3f40f3b6fdf036bff73832357634?d=identicon&amp;s=20" />
      Alastair Douglas
      </a>
    </li>
    <li class="contributor"
      data-cpan-author="ARISTOTLE"
      data-contrib-email="pagaltzis@gmx.de"
    >
      <a href="https://metacpan.org/author/ARISTOTLE" class="cpan-author">
      <img class="gravatar" width="20" height="20" src="https://www.gravatar.com/avatar/81da52fa1b6754867e9056c58afab74d?d=identicon&amp;s=20" />
      Aristotle Pagaltzis
      </a>
    </li>
    <li class="contributor"
      data-contrib-email="chase.whitener@infotechfl.com"
    >
      <img class="gravatar" width="20" height="20" src="https://www.gravatar.com/avatar/d41d8cd98f00b204e9800998ecf8427e?d=identicon&amp;s=20" />
      Chase Whitener
    </li>
    <li class="contributor"
      data-contrib-email="webmaster@cosmicperl.com"
    >
      <img class="gravatar" width="20" height="20" src="https://www.gravatar.com/avatar/d41d8cd98f00b204e9800998ecf8427e?d=identicon&amp;s=20" />
      CosmicNet
    </li>
    <li class="contributor"
      data-contrib-email="grinnz@gmail.com"
    >
      <img class="gravatar" width="20" height="20" src="https://www.gravatar.com/avatar/d41d8cd98f00b204e9800998ecf8427e?d=identicon&amp;s=20" />
      Dan Book
    </li>
    <li class="contributor"
      data-cpan-author="FREW"
      data-contrib-email="frioux@gmail.com"
    >
      <a href="https://metacpan.org/author/FREW" class="cpan-author">
      <img class="gravatar" width="20" height="20" src="https://www.gravatar.com/avatar/99d7d0aba169ea255ffa5c8c63f652ae?d=identicon&amp;s=20" />
      fREW Schmidt
      </a>
    </li>
    <li class="contributor"
      data-contrib-email="jjn1056@yahoo.com"
    >
      <img class="gravatar" width="20" height="20" src="https://www.gravatar.com/avatar/d41d8cd98f00b204e9800998ecf8427e?d=identicon&amp;s=20" />
      John Napiorkowski
    </li>
    <li class="contributor"
      data-contrib-email="github@stompro.org"
    >
      <img class="gravatar" width="20" height="20" src="https://www.gravatar.com/avatar/d41d8cd98f00b204e9800998ecf8427e?d=identicon&amp;s=20" />
      Josh Stompro
    </li>
    <li class="contributor"
      data-contrib-email="tewk@tan.tewk.com"
    >
      <img class="gravatar" width="20" height="20" src="https://www.gravatar.com/avatar/d41d8cd98f00b204e9800998ecf8427e?d=identicon&amp;s=20" />
      Kevin Tew
    </li>
    <li class="contributor"
      data-contrib-email="kd@fenchurch.local"
    >
      <img class="gravatar" width="20" height="20" src="https://www.gravatar.com/avatar/d41d8cd98f00b204e9800998ecf8427e?d=identicon&amp;s=20" />
      Kieren Diment
    </li>
    <li class="contributor"
      data-contrib-email="kris@tigerlms.com"
    >
      <img class="gravatar" width="20" height="20" src="https://www.gravatar.com/avatar/d41d8cd98f00b204e9800998ecf8427e?d=identicon&amp;s=20" />
      Kris Matthews
    </li>
    <li class="contributor"
      data-contrib-email="lee@givengain.ch"
    >
      <img class="gravatar" width="20" height="20" src="https://www.gravatar.com/avatar/d41d8cd98f00b204e9800998ecf8427e?d=identicon&amp;s=20" />
      Lee Johnson
    </li>
    <li class="contributor"
      data-contrib-email="github@lxxi.org"
    >
      <img class="gravatar" width="20" height="20" src="https://www.gravatar.com/avatar/d41d8cd98f00b204e9800998ecf8427e?d=identicon&amp;s=20" />
      Manni Heumann
    </li>
    <li class="contributor"
      data-cpan-author="PALI"
      data-contrib-email="pali@cpan.org"
    >
      <a href="https://metacpan.org/author/PALI" class="cpan-author">
      <img class="gravatar" width="20" height="20" src="https://www.gravatar.com/avatar/d8f03d10174e68c6f26d9052b79e04e8?d=identicon&amp;s=20" />
      Pali
      </a>
    </li>
    <li class="contributor"
      data-contrib-email="rjbs@semiotic.systems"
    >
      <img class="gravatar" width="20" height="20" src="https://www.gravatar.com/avatar/d41d8cd98f00b204e9800998ecf8427e?d=identicon&amp;s=20" />
      Ricardo Signes
    </li>
    <li class="contributor"
      data-contrib-email="ross.attrill@gmail.com"
    >
      <img class="gravatar" width="20" height="20" src="https://www.gravatar.com/avatar/d41d8cd98f00b204e9800998ecf8427e?d=identicon&amp;s=20" />
      Ross Attrill
    </li>
    <li class="contributor"
      data-contrib-email="russell.jenkins@strategicdata.com.au"
    >
      <img class="gravatar" width="20" height="20" src="https://www.gravatar.com/avatar/d41d8cd98f00b204e9800998ecf8427e?d=identicon&amp;s=20" />
      Russell Jenkins
    </li>
    <li class="contributor"
      data-contrib-email="shawn@coloredblocks.com"
    >
      <img class="gravatar" width="20" height="20" src="https://www.gravatar.com/avatar/d41d8cd98f00b204e9800998ecf8427e?d=identicon&amp;s=20" />
      Shawn Sorichetti
    </li>
    <li class="contributor"
      data-cpan-author="STEVIED"
      data-contrib-email="s@dondley.com"
    >
      <a href="https://metacpan.org/author/STEVIED" class="cpan-author">
      <img class="gravatar" width="20" height="20" src="https://www.gravatar.com/avatar/d05810eb5aa00f693481dcbfd8cc0317?d=identicon&amp;s=20" />
      Steve Dondley
      </a>
    </li>
    <li class="contributor"
      data-contrib-email="tokuhirom@gmail.com"
    >
      <img class="gravatar" width="20" height="20" src="https://www.gravatar.com/avatar/d41d8cd98f00b204e9800998ecf8427e?d=identicon&amp;s=20" />
      tokuhirom
    </li>
  </ul>
</div>
    </li>
              </ul>
            </div>
          </nav>
          <div class="content-navigation">
<div class="breadcrumbs">
  <span>
    <a data-keyboard-shortcut="g a" rel="author" href="https://metacpan.org/author/RJBS" class="author-name">Ricardo SIGNES 😄</a>
  </span>
  <span>&nbsp;/&nbsp;</span>
  <div class="release dist-release status-latest maturity-released">
    <span class="dropdown"><b class="caret"></b></span>
<select onchange="document.location.href=&#39;/release/&#39;+this.value+&#39;/view/lib/Email/Stuffer.pm&#39;" class="">
<option
  selected
  value="RJBS/Email-Stuffer-0.020"
>0.020
  (RJBS on 2023-01-11)</option>
<option
  
  value="RJBS/Email-Stuffer-0.019"
>0.019
  (RJBS on 2023-01-10)</option>
<optgroup label="BackPAN">'
<option
  
  value="RJBS/Email-Stuffer-0.018"
>0.018
  (RJBS on 2020-07-03)</option>
<option
  
  value="RJBS/Email-Stuffer-0.017"
>0.017
  (RJBS on 2018-03-10)</option>
<option
  
  value="RJBS/Email-Stuffer-0.016"
>0.016
  (RJBS on 2017-08-31)</option>
<option
  
  value="RJBS/Email-Stuffer-0.015-TRIAL"
>0.015-TRIAL DEV
  (RJBS on 2017-06-25)</option>
<option
  
  value="RJBS/Email-Stuffer-0.014"
>0.014
  (RJBS on 2016-04-30)</option>
<option
  
  value="RJBS/Email-Stuffer-0.013"
>0.013
  (RJBS on 2016-04-09)</option>
<option
  
  value="RJBS/Email-Stuffer-0.012"
>0.012
  (RJBS on 2015-02-16)</option>
<option
  
  value="RJBS/Email-Stuffer-0.011"
>0.011
  (RJBS on 2015-02-15)</option>
<option
  
  value="RJBS/Email-Stuffer-0.010-TRIAL"
>0.010-TRIAL DEV
  (RJBS on 2014-04-25)</option>
<option
  
  value="RJBS/Email-Stuffer-0.009"
>0.009
  (RJBS on 2013-11-25)</option>
<option
  
  value="RJBS/Email-Stuffer-0.008"
>0.008
  (RJBS on 2013-09-29)</option>
<option
  
  value="RJBS/Email-Stuffer-0.007"
>0.007
  (RJBS on 2013-08-22)</option>
<option
  
  value="RJBS/Email-Stuffer-0.006"
>0.006
  (RJBS on 2013-07-02)</option>
<option
  
  value="RJBS/Email-Stuffer-0.005"
>0.005
  (RJBS on 2013-07-02)</option>
<option
  
  value="RJBS/Email-Stuffer-0.004"
>0.004
  (RJBS on 2013-06-25)</option>
<option
  
  value="RJBS/Email-Stuffer-0.003"
>0.003
  (RJBS on 2013-06-19)</option>
<option
  
  value="RJBS/Email-Stuffer-0.002"
>0.002
  (RJBS on 2013-06-14)</option>
<option
  
  value="RJBS/Email-Stuffer-0.001"
>0.001
  (RJBS on 2013-05-30)</option>
</optgroup>
</select>
    <a data-keyboard-shortcut="g d" class="release-name" href="https://metacpan.org/dist/Email-Stuffer">Email-Stuffer-0.020</a>
  </div>
<span class="river-gauge-gauge">
  <svg width="24px"
       height="15px"
       version="1.1"
       xmlns="http://www.w3.org/2000/svg"
       xmlns:xlink="http://www.w3.org/1999/xlink">

    <g>
      <title>        River stage two &#10;
          • 10 direct dependents &#10;          • 13 total dependents
      </title>

      <rect x="0"  y="0" width="4" height="15" fill="#7ea3f2" />
      <rect x="5"  y="0" width="4" height="15" fill="#7ea3f2" />
      <rect x="10"  y="0" width="4" height="15" fill="#e4e2e2" />
      <rect x="15"  y="0" width="4" height="15" fill="#e4e2e2" />
      <rect x="20"  y="0" width="4" height="15" fill="#e4e2e2" />
    </g>
  </svg>

</span>
<div id="Email-Stuffer-fav" class="logged_in">
<form action="https://metacpan.org/account/favorite/add" style="display: inline" onsubmit="return favDistribution(this)">
    <input type="hidden" name="remove" value="0">
    <input type="hidden" name="release" value="Email-Stuffer-0.020">
    <input type="hidden" name="author" value="RJBS">
    <input type="hidden" name="distribution" value="Email-Stuffer">
    <button type="submit" class="favorite highlight"><span>34</span> ++</button>
</form>
</div>
<div class="logged_out">
<a href="./Email::Stuffer.html" onclick="alert('Please sign in to add favorites'); return false" class="favorite highlight">
<span>34</span> ++</a>
</div>
   / <span>Email::Stuffer</span>
</div>
          </div>
          <main class="content">


<nav class="toc">
  <div class="toc-header"><strong>Contents</strong></div>
<ul>
  <li><a href="./Email::Stuffer.html#NAME">NAME</a></li>
  <li><a href="./Email::Stuffer.html#VERSION">VERSION</a></li>
  <li><a href="./Email::Stuffer.html#SYNOPSIS">SYNOPSIS</a></li>
  <li><a href="./Email::Stuffer.html#DESCRIPTION">DESCRIPTION</a>
    <ul>
      <li><a href="./Email::Stuffer.html#Default-Transport">Default Transport</a></li>
      <li><a href="./Email::Stuffer.html#Why-use-this?">Why use this?</a></li>
    </ul>
  </li>
  <li><a href="./Email::Stuffer.html#PERL-VERSION">PERL VERSION</a></li>
  <li><a href="./Email::Stuffer.html#METHODS">METHODS</a>
    <ul>
      <li><a href="./Email::Stuffer.html#new">new</a></li>
      <li><a href="./Email::Stuffer.html#header_names">header_names</a></li>
      <li><a href="./Email::Stuffer.html#parts">parts</a></li>
      <li><a href="./Email::Stuffer.html#header">header</a></li>
      <li><a href="./Email::Stuffer.html#to">to</a></li>
      <li><a href="./Email::Stuffer.html#from">from</a></li>
      <li><a href="./Email::Stuffer.html#reply_to">reply_to</a></li>
      <li><a href="./Email::Stuffer.html#cc">cc</a></li>
      <li><a href="./Email::Stuffer.html#bcc">bcc</a></li>
      <li><a href="./Email::Stuffer.html#subject">subject</a></li>
      <li><a href="./Email::Stuffer.html#text_body">text_body</a></li>
      <li><a href="./Email::Stuffer.html#html_body">html_body</a></li>
      <li><a href="./Email::Stuffer.html#attach">attach</a></li>
      <li><a href="./Email::Stuffer.html#attach_file">attach_file</a></li>
      <li><a href="./Email::Stuffer.html#transport">transport</a></li>
      <li><a href="./Email::Stuffer.html#email">email</a></li>
      <li><a href="./Email::Stuffer.html#as_string">as_string</a></li>
      <li><a href="./Email::Stuffer.html#send">send</a></li>
      <li><a href="./Email::Stuffer.html#send_or_die">send_or_die</a></li>
    </ul>
  </li>
  <li><a href="./Email::Stuffer.html#COOKBOOK">COOKBOOK</a>
    <ul>
      <li><a href="./Email::Stuffer.html#Custom-Alerts">Custom Alerts</a></li>
    </ul>
  </li>
  <li><a href="./Email::Stuffer.html#TO-DO">TO DO</a></li>
  <li><a href="./Email::Stuffer.html#SEE-ALSO">SEE ALSO</a></li>
  <li><a href="./Email::Stuffer.html#AUTHORS">AUTHORS</a></li>
  <li><a href="./Email::Stuffer.html#CONTRIBUTORS">CONTRIBUTORS</a></li>
  <li><a href="./Email::Stuffer.html#COPYRIGHT-AND-LICENSE">COPYRIGHT AND LICENSE</a></li>
</ul></nav>
<div class="pod anchors">
<h1 id="NAME">NAME</h1>

<p>Email::Stuffer - A more casual approach to creating and sending Email:: emails</p>

<h1 id="VERSION">VERSION</h1>

<p>version 0.020</p>

<h1 id="SYNOPSIS">SYNOPSIS</h1>

<pre><code>  # Prepare the message
  my $body = &lt;&lt;&#39;AMBUSH_READY&#39;;
  Dear Santa

  I have killed Bun Bun.

  Yes, I know what you are thinking... but it was actually a total accident.

  I was in a crowded line at a BayWatch signing, and I tripped, and stood on
  his head.

  I know. Oops! :/

  So anyways, I am willing to sell you the body for $1 million dollars.

  Be near the pinhole to the Dimension of Pain at midnight.

  Alias

  AMBUSH_READY

  # Create and send the email in one shot
  Email::Stuffer-&gt;from     (&#39;cpan@ali.as&#39;             )
                -&gt;to       (&#39;santa@northpole.org&#39;     )
                -&gt;bcc      (&#39;bunbun@sluggy.com&#39;       )
                -&gt;text_body($body                     )
                -&gt;attach_file(&#39;dead_bunbun_faked.gif&#39; )
                -&gt;send;</code></pre>

<h1 id="DESCRIPTION">DESCRIPTION</h1>

<p><b>The basics should all work, but this module is still subject to name and/or API changes</b></p>

<p>Email::Stuffer, as its name suggests, is a fairly casual module used to stuff things into an email and send them. It is a high-level module designed for ease of use when doing a very specific common task, but implemented on top of the light and tolerable Email:: modules.</p>

<p>Email::Stuffer is typically used to build emails and send them in a single statement, as seen in the synopsis. And it is certain only for use when creating and sending emails. As such, it contains no email parsing capability, and little to no modification support.</p>

<p>To re-iterate, this is very much a module for those &quot;slap it together and fire it off&quot; situations, but that still has enough grunt behind the scenes to do things properly.</p>

<h2 id="Default-Transport"><a id="Default"></a>Default Transport</h2>

<p>Although it cannot be relied upon to work, the default behaviour is to use <code>sendmail</code> to send mail, if you don&#39;t provide the mail send channel with either the <code>transport</code> method, or as an argument to <code>send</code>.</p>

<p>(Actually, the choice of default is delegated to <a href="./Email::Sender::Simple.html">Email::Sender::Simple</a>, which makes its own choices. But usually, it uses <code>sendmail</code>.)</p>

<h2 id="Why-use-this?"><a id="Why"></a><a id="Why-use-this"></a>Why use this?</h2>

<p>Why not just use <a href="https://metacpan.org/pod/Email::Simple">Email::Simple</a> or <a href="./Email::MIME.html">Email::MIME</a>? After all, this just adds another layer of stuff around those. Wouldn&#39;t using them directly be better?</p>

<p>Certainly, if you know EXACTLY what you are doing. The docs are clear enough, but you really do need to have an understanding of the structure of MIME emails. This structure is going to be different depending on whether you have text body, HTML, both, with or without an attachment etc.</p>

<p>Then there&#39;s brevity... compare the following roughly equivalent code.</p>

<p>First, the Email::Stuffer way.</p>

<pre><code>  Email::Stuffer-&gt;to(&#39;Simon Cozens&lt;simon@somewhere.jp&gt;&#39;)
                -&gt;from(&#39;Santa@northpole.org&#39;)
                -&gt;text_body(&quot;You&#39;ve been good this year. No coal for you.&quot;)
                -&gt;attach_file(&#39;choochoo.gif&#39;)
                -&gt;send;</code></pre>

<p>And now doing it directly with a knowledge of what your attachment is, and what the correct MIME structure is.</p>

<pre><code>  use Email::MIME;
  use Email::Sender::Simple;
  use IO::All;

  Email::Sender::Simple-&gt;try_to_send(
    Email::MIME-&gt;create(
      header =&gt; [
          To =&gt; &#39;simon@somewhere.jp&#39;,
          From =&gt; &#39;santa@northpole.org&#39;,
      ],
      parts =&gt; [
          Email::MIME-&gt;create(
            body =&gt; &quot;You&#39;ve been a good boy this year. No coal for you.&quot;
          ),
          Email::MIME-&gt;create(
            body =&gt; io(&#39;choochoo.gif&#39;),
            attributes =&gt; {
                filename =&gt; &#39;choochoo.gif&#39;,
                content_type =&gt; &#39;image/gif&#39;,
            },
         ),
      ],
    );
  );</code></pre>

<p>Again, if you know MIME well, and have the patience to manually code up the <a href="./Email::MIME.html">Email::MIME</a> structure, go do that, if you really want to.</p>

<p>Email::Stuffer as the name suggests, solves one case and one case only: generate some stuff, and email it to somewhere, as conveniently as possible. DWIM, but do it as thinly as possible and use the solid Email:: modules underneath.</p>

<h1 id="PERL-VERSION"><a id="PERL"></a>PERL VERSION</h1>

<p>This library should run on perls released even a long time ago. It should work on any version of perl released in the last five years.</p>

<p>Although it may work on older versions of perl, no guarantee is made that the minimum required version will not be increased. The version may be increased for any reason, and there is no promise that patches will be accepted to lower the minimum required perl.</p>

<h1 id="METHODS">METHODS</h1>

<p>As you can see from the synopsis, all methods that <b>modify</b> the Email::Stuffer object returns the object, and thus most normal calls are chainable.</p>

<p>However, please note that <code>send</code>, and the group of methods that do not change the Email::Stuffer object <b>do not</b> return the object, and thus <b>are not</b> chainable.</p>

<h2 id="new">new</h2>

<p>Creates a new, empty, Email::Stuffer object.</p>

<p>You can pass a hashref of properties to set, including:</p>

<ul>

<li><p>to</p>

</li>
<li><p>from</p>

</li>
<li><p>cc</p>

</li>
<li><p>bcc</p>

</li>
<li><p>reply_to</p>

</li>
<li><p>subject</p>

</li>
<li><p>text_body</p>

</li>
<li><p>html_body</p>

</li>
<li><p>transport</p>

</li>
</ul>

<p>The to, cc, bcc, and reply_to headers properties may be provided as array references. The array&#39;s contents will be used as the list of arguments to the setter.</p>

<h2 id="header_names">header_names</h2>

<p>Returns, as a list, all of the headers currently set for the Email For backwards compatibility, this method can also be called as B[headers].</p>

<h2 id="parts">parts</h2>

<p>Returns, as a list, the <a href="./Email::MIME.html">Email::MIME</a> parts for the Email</p>

<h2 id="header">header</h2>

<pre><code>  $stuffer-&gt;header($header_name = $value)</code></pre>

<p>This method sets a named header in the email. Multiple calls with the same <code>$header_name</code> will overwrite previous calls <code>$value</code>.</p>

<h2 id="to">to</h2>

<pre><code>  $stuffer-&gt;to(@addresses)</code></pre>

<p>This method sets the To header in the email.</p>

<h2 id="from">from</h2>

<pre><code>  $stuffer-&gt;from($address)</code></pre>

<p>This method sets the From header in the email.</p>

<h2 id="reply_to">reply_to</h2>

<pre><code>  $stuffer-&gt;reply_to($address)</code></pre>

<p>This method sets the Reply-To header in the email.</p>

<h2 id="cc">cc</h2>

<pre><code>  $stuffer-&gt;cc(@addresses)</code></pre>

<p>This method sets the Cc header in the email.</p>

<h2 id="bcc">bcc</h2>

<pre><code>  $stuffer-&gt;bcc(@addresses)</code></pre>

<p>This method sets the Bcc header in the email.</p>

<h2 id="subject">subject</h2>

<pre><code>  $stuffer-&gt;subject($text)</code></pre>

<p>This method sets the Subject header in the email.</p>

<h2 id="text_body">text_body</h2>

<pre><code>  $stuffer-&gt;text_body($body, %attributes);</code></pre>

<p>Sets the text body of the email. Appropriate headers are set for you. You may override MIME attributes as needed. See the <code>attributes</code> parameter to <a href="./Email::MIME.html#create">&quot;create&quot; in Email::MIME</a> for the headers you can set.</p>

<p>If <code>$body</code> is undefined, this method will do nothing.</p>

<p>Prior to Email::Stuffer version 0.015 text body was marked as flowed, which broke all pre-formated body text. Empty space at the beggining of the line was dropped and every new line character could be changed to one space (and vice versa). Version 0.015 (and later) does not set flowed format automatically anymore and so text body is really plain text. If you want to use old behavior of &quot;advanced&quot; flowed formatting, set flowed format manually by: <code>text_body($body, format =&gt; &#39;flowed&#39;)</code>.</p>

<h2 id="html_body">html_body</h2>

<pre><code>  $stuffer-&gt;html_body($body, %attributes);</code></pre>

<p>Sets the HTML body of the email. Appropriate headers are set for you. You may override MIME attributes as needed. See the <code>attributes</code> parameter to <a href="./Email::MIME.html#create">&quot;create&quot; in Email::MIME</a> for the headers you can set.</p>

<p>If <code>$body</code> is undefined, this method will do nothing.</p>

<h2 id="attach">attach</h2>

<pre><code>  $stuffer-&gt;attach($contents, %attributes)</code></pre>

<p>Adds an attachment to the email. The first argument is the file contents followed by (as for text_body and html_body) the list of headers to use. Email::Stuffer will <i>try</i> to guess the headers correctly, but you may wish to provide them anyway to be sure. Encoding is Base64 by default. See the <code>attributes</code> parameter to <a href="./Email::MIME.html#create">&quot;create&quot; in Email::MIME</a> for the headers you can set.</p>

<h2 id="attach_file">attach_file</h2>

<pre><code>  $stuffer-&gt;attach_file($file, %attributes)</code></pre>

<p>Attachs a file that already exists on the filesystem to the email. <code>attach_file</code> will attempt to auto-detect the MIME type, and use the file&#39;s current name when attaching. See the <code>attributes</code> parameter to <a href="./Email::MIME.html#create">&quot;create&quot; in Email::MIME</a> for the headers you can set.</p>

<p><code>$file</code> can be a filename or an IO::All::File object.</p>

<h2 id="transport">transport</h2>

<pre><code>  $stuffer-&gt;transport( $moniker, @options )</code></pre>

<p>or</p>

<pre><code>  $stuffer-&gt;transport( $transport_obj )</code></pre>

<p>The <code>transport</code> method specifies the <a href="https://metacpan.org/pod/Email::Sender">Email::Sender</a> transport that you want to use to send the email, and any options that need to be used to instantiate the transport. <code>$moniker</code> is used as the transport name; if it starts with an equals sign (<code>=</code>) then the text after the sign is used as the class. Otherwise, the text is prepended by <code>Email::Sender::Transport::</code>.</p>

<p>Alternatively, you can pass a complete transport object (which must be an <a href="https://metacpan.org/pod/Email::Sender::Transport">Email::Sender::Transport</a> object) and it will be used as is.</p>

<h2 id="email">email</h2>

<pre><code>  my $email_mime = $stuffer-&gt;email;</code></pre>

<p>This method creates and returns the full <a href="./Email::MIME.html">Email::MIME</a> object for the email.</p>

<h2 id="as_string">as_string</h2>

<pre><code>  my $email_document = $stuffer-&gt;as_string;</code></pre>

<p>Returns the string form of the email. Identical to (and uses behind the scenes) <code>Email::MIME-&gt;as_string</code>.</p>

<h2 id="send">send</h2>

<pre><code>  $stuffer-&gt;send;</code></pre>

<p>or</p>

<pre><code>  $stuffer-&gt;send({ to =&gt; [ $to_1, $to_2 ], from =&gt; $sender });</code></pre>

<p>Sends the email via <a href="./Email::Sender::Simple.html">Email::Sender::Simple</a>. <a href="https://metacpan.org/pod/Email::Sender::Manual::QuickStart#envelope-information">Envelope information</a> can be specified in a hash reference.</p>

<p>On failure, returns false.</p>

<h2 id="send_or_die">send_or_die</h2>

<pre><code>  $stuffer-&gt;send_or_die;</code></pre>

<p>or</p>

<pre><code>  $stuffer-&gt;send_or_die({ to =&gt; [ $to_1, $to_2 ], from =&gt; $sender });</code></pre>

<p>Sends the email via <a href="./Email::Sender::Simple.html">Email::Sender::Simple</a>. <a href="https://metacpan.org/pod/Email::Sender::Manual::QuickStart#envelope-information">Envelope information</a> can be specified in a hash reference.</p>

<p>On failure, throws an exception.</p>

<h1 id="COOKBOOK">COOKBOOK</h1>

<p>Here is another example (maybe plural later) of how you can use Email::Stuffer&#39;s brevity to your advantage.</p>

<h2 id="Custom-Alerts"><a id="Custom"></a>Custom Alerts</h2>

<pre><code>  package SMS::Alert;
  use base &#39;Email::Stuffer&#39;;

  sub new {
    shift()-&gt;SUPER::new(@_)
           -&gt;from(&#39;monitor@my.website&#39;)
           # Of course, we could have pulled these from
           # $MyConfig-&gt;{support_tech} or something similar.
           -&gt;to(&#39;0416181595@sms.gateway&#39;)
           -&gt;transport(&#39;SMTP&#39;, { host =&gt; &#39;123.123.123.123&#39; });
  }</code></pre>

<p></p>

<pre><code>  package My::Code;

  unless ( $Server-&gt;restart ) {
          # Notify the admin on call that a server went down and failed
          # to restart.
          SMS::Alert-&gt;subject(&quot;Server $Server failed to restart cleanly&quot;)
                    -&gt;send;
  }</code></pre>

<h1 id="TO-DO"><a id="TO"></a>TO DO</h1>

<ul>

<li><p>Fix a number of bugs still likely to exist</p>

</li>
<li><p>Write more tests.</p>

</li>
<li><p>Add any additional small bit of automation that isn&#39;t too expensive</p>

</li>
</ul>

<h1 id="SEE-ALSO"><a id="SEE"></a>SEE ALSO</h1>

<p><a href="./Email::MIME.html">Email::MIME</a>, <a href="https://metacpan.org/pod/Email::Sender">Email::Sender</a>, <a href="http://ali.as/">http://ali.as/</a></p>

<h1 id="AUTHORS">AUTHORS</h1>

<ul>

<li><p>Adam Kennedy &lt;adamk@cpan.org&gt;</p>

</li>
<li><p>Ricardo SIGNES &lt;cpan@semiotic.systems&gt;</p>

</li>
</ul>

<h1 id="CONTRIBUTORS">CONTRIBUTORS</h1>

<ul>

<li><p>Aaron W. Swenson &lt;aaron.w.swenson@gmail.com&gt;</p>

</li>
<li><p>adam &lt;adam@88f4d9cd-8a04-0410-9d60-8f63309c3137&gt;</p>

</li>
<li><p>adamk@cpan.org &lt;adamk@cpan.org@88f4d9cd-8a04-0410-9d60-8f63309c3137&gt;</p>

</li>
<li><p>adam@phase-n.com &lt;adam@phase-n.com@88f4d9cd-8a04-0410-9d60-8f63309c3137&gt;</p>

</li>
<li><p>Alastair Douglas &lt;altreus@altre.us&gt;</p>

</li>
<li><p>Aristotle Pagaltzis &lt;pagaltzis@gmx.de&gt;</p>

</li>
<li><p>Chase Whitener &lt;chase.whitener@infotechfl.com&gt;</p>

</li>
<li><p>CosmicNet &lt;webmaster@cosmicperl.com&gt;</p>

</li>
<li><p>Dan Book &lt;grinnz@gmail.com&gt;</p>

</li>
<li><p>fREW Schmidt &lt;frioux@gmail.com&gt;</p>

</li>
<li><p>John Napiorkowski &lt;jjn1056@yahoo.com&gt;</p>

</li>
<li><p>Josh Stompro &lt;github@stompro.org&gt;</p>

</li>
<li><p>Kevin Tew &lt;tewk@tan.tewk.com&gt;</p>

</li>
<li><p>Kieren Diment &lt;kd@fenchurch.local&gt;</p>

</li>
<li><p>Kris Matthews &lt;kris@tigerlms.com&gt;</p>

</li>
<li><p>Lee Johnson &lt;lee@givengain.ch&gt;</p>

</li>
<li><p>Manni Heumann &lt;github@lxxi.org&gt;</p>

</li>
<li><p>Pali &lt;pali@cpan.org&gt;</p>

</li>
<li><p>Ricardo Signes &lt;rjbs@semiotic.systems&gt;</p>

</li>
<li><p>Ross Attrill &lt;ross.attrill@gmail.com&gt;</p>

</li>
<li><p>Russell Jenkins &lt;russell.jenkins@strategicdata.com.au&gt;</p>

</li>
<li><p>Shawn Sorichetti &lt;shawn@coloredblocks.com&gt;</p>

</li>
<li><p>Steve Dondley &lt;s@dondley.com&gt;</p>

</li>
<li><p>tokuhirom &lt;tokuhirom@gmail.com&gt;</p>

</li>
</ul>

<h1 id="COPYRIGHT-AND-LICENSE"><a id="COPYRIGHT"></a>COPYRIGHT AND LICENSE</h1>

<p>This software is copyright (c) 2004 by Adam Kennedy and Ricardo SIGNES.</p>

<p>This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.</p></div>

<div id="metacpan_install-instructions-dialog" class="modal fade">
  <div class="modal-dialog">
    <div class="modal-content">
      <div class="modal-header">
        <button type="button" class="close" data-dismiss="modal" aria-hidden="true">&times;</button>
        <h4 class="modal-title">Module Install Instructions</h4>
      </div>
      <div class="modal-body">
        <p>To install Email::Stuffer, copy and paste the appropriate command in to your terminal.</p>
        <p><a href="https://metacpan.org/dist/App-cpanminus/view/bin/cpanm">cpanm</a></p>
        <pre><code>cpanm Email::Stuffer</code></pre>
        <p><a href="https://metacpan.org/pod/CPAN">CPAN shell</a></p>
        <pre><code>perl -MCPAN -e shell
install Email::Stuffer</code></pre>
        <p>For more information on module installation, please visit <a href="https://www.cpan.org/modules/INSTALL.html">the detailed CPAN module installation guide</a>.</p>
      </div>
      <div class="modal-footer">
        <a href="./Email::Stuffer.html#" data-dismiss="modal" class="btn">Close</a>
      </div>
    </div>
  </div>
</div>
          </main>
          <div class="content-pagination">
          </div>
        </div>
        <footer class="footer">
          <div class="footer-container">
            <div class="footer-social">
              <div class="footer-link footer-logo">
                <a href="https://metacpan.org/">
                  <img src="https://metacpan.org/static/images/metacpan-logo.svg" alt="MetaCPAN" />
                </a>
              </div>
              <a class="footer-social-link" href="https://github.com/metacpan">
                <i class="fab fa-github-square"></i>
              </a>
              <a class="footer-social-link" href="https://fosstodon.org/@metacpan">
                <i class="fab fa-mastodon"></i>
              </a>
            </div>
            <div class="footer-links">
              <div class="footer-link">
                  <a href="https://metacpan.org/about">About</a>
              </div>
              <div class="footer-link">
                  <a href="https://metacpan.org/about/sponsors">Sponsor</a>
              </div>
              <div class="footer-link">
                  <a href="https://grep.metacpan.org">grep::cpan</a>
              </div>
              <div class="footer-link">
                  <a href="https://metacpan.org/recent">Recent</a>
              </div>
              <div class="footer-link">
                  <a href="https://metacpan.org/about/faq">FAQ</a>
              </div>
              <div class="footer-link">
                  <a href="https://metacpan.org/tools">Tools</a>
              </div>
              <div class="footer-link">
                  <a href="https://fastapi.metacpan.org/">API</a>
              </div>
              <div class="footer-link">
                  <a href="https://www.perl.org/">Perl.org</a>
              </div>
            </div>
            <div class="footer-sponsors">
              <a class="footer-sponsor-link" target="_blank" href="https://www.bytemark.co.uk/" rel="noopener">
                <img class="footer-sponsor-bytemark" src="https://metacpan.org/static/images/sponsors/bytemark_logo.svg" alt="Bytemark logo">
              </a>
              <a class="footer-sponsor-link" target="_blank" href="https://www.liquidweb.com/" rel="noopener">
                <img class="footer-sponsor-liquidweb" src="https://metacpan.org/static/images/sponsors/liquidweb_logo.png" alt="liquidweb logo">
              </a>
              <a class="footer-sponsor-link" target="_blank" href="https://deriv.com/careers/" rel="noopener">
                <img class="footer-sponsor-deriv" src="https://metacpan.org/static/images/sponsors/deriv.svg" alt="Deriv logo">
              </a>
              <a class="footer-sponsor-link" target="_blank" href="https://geocode.xyz" rel="noopener">
                <img class="footer-sponsor-geocode" src="https://metacpan.org/static/images/sponsors/geocodelogo.svg" alt="Geocode logo">
              </a>
              <a class="footer-sponsor-link" target="_blank" href="https://www.fastly.com/" rel="noopener">
                <img class="footer-sponsor-fastly" src="https://metacpan.org/static/images/sponsors/fastly_logo.svg" alt="Fastly logo">
              </a>
              <a class="footer-sponsor-link" target="_blank" href="https://opencagedata.com" rel="noopener">
                <img class="footer-sponsor-opencage" src="https://metacpan.org/static/images/sponsors/open-cage.svg" alt="OpenCage logo">
              </a>
            </div>
          </div>
        </footer>
        <div class="modal fade" tabindex="-1" role="dialog" id="metacpan_keyboard-shortcuts">
          <div class="modal-dialog">
            <div class="modal-content">
              <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal">&times;</button>
                <h4 class="modal-title">Keyboard Shortcuts</h4>
              </div>
              <div class="modal-body row">
<div class="col-md-6">
  <table class="table keyboard-shortcuts">
    <thead>
      <tr>
        <th></th>
        <th>Global</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td class="keys">
          <kbd>s</kbd>
        </td>
        <td>Focus search bar</td>
      </tr>
      <tr>
        <td class="keys">
          <kbd>?</kbd>
        </td>
        <td>Bring up this help dialog</td>
      </tr>
    </tbody>
  </table>

  <table class="table keyboard-shortcuts">
    <thead>
      <tr>
        <th></th>
        <th>GitHub</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td class="keys">
          <kbd>g</kbd> <kbd>p</kbd>
        </td>
        <td>Go to pull requests</td>
      </tr>
      <tr>
        <td class="keys">
          <kbd>g</kbd> <kbd>i</kbd>
        </td>
        <td>go to github issues (only if github is preferred repository)</td>
      </tr>
    </tbody>
  </table>
</div>

<div class="col-md-6">
  <table class="table keyboard-shortcuts">
    <thead>
      <tr>
        <th></th>
        <th>POD</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td class="keys">
          <kbd>g</kbd> <kbd>a</kbd>
        </td>
        <td>Go to author</td>
      </tr>
      <tr>
        <td class="keys">
          <kbd>g</kbd> <kbd>c</kbd>
        </td>
        <td>Go to changes</td>
      </tr>
      <tr>
        <td class="keys">
          <kbd>g</kbd> <kbd>i</kbd>
        </td>
        <td>Go to issues</td>
      </tr>
      <tr>
        <td class="keys">
          <kbd>g</kbd> <kbd>d</kbd>
        </td>
        <td>Go to dist</td>
      </tr>
      <tr>
        <td class="keys">
          <kbd>g</kbd> <kbd>r</kbd>
        </td>
        <td>Go to repository/SCM</td>
      </tr>
      <tr>
        <td class="keys">
          <kbd>g</kbd> <kbd>s</kbd>
        </td>
        <td>Go to source</td>
      </tr>
      <tr>
        <td class="keys">
          <kbd>g</kbd> <kbd>b</kbd>
        </td>
        <td>Go to file browse</td>
      </tr>

    </tbody>
  </table>
</div>

<div class="col-md-12">
  <table class="table keyboard-shortcuts">
    <thead>
      <tr>
        <th></th>
        <th>Search terms</th>
      </tr>
    </thead>
    <tbody>
      <tr>
        <td><em>module:</em> (e.g. <a href="https://metacpan.org/search?q=module%3APlugin">module:Plugin</a>)</td>
      </tr>
      <tr>
        <td><em>distribution:</em> (e.g. <a href="https://metacpan.org/search?q=distribution%3ADancer+auth">distribution:Dancer auth</a>)</td>
      </tr>
      <tr>
        <td><em>author:</em> (e.g. <a href="https://metacpan.org/search?q=author%3ASONGMU+Redis">author:SONGMU Redis</a>)</td>
      </tr>
      <tr>
        <td><em>version:</em> (e.g. <a href="https://metacpan.org/search?q=version%3A1.00">version:1.00</a>)</td>
      </tr>
    </tbody>
  </table>
</div>
              </div>
              <div class="modal-footer"></div>
            </div>
          </div>
        </div>
    </body>
</html>
